From: Owen Taylor Date: Mon, 3 Nov 2008 21:39:41 +0000 (+0000) Subject: Don't override XAUTHORITY until after we run Xephyr X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~11611 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=e82e60f71b823f0430deb87013ba734091ced6f4;p=gnome-shell.git Don't override XAUTHORITY until after we run Xephyr Don't override the setting of XAUTHORITY when running Xephyr, since then we may not be able to connect to the host display. Instead pass in the local auth file via the -auth command line argument. An alternate fix would be to use 'xauth merge' to merge the existing XAUTHORITY file into our local file. svn path=/trunk/; revision=29 --- diff --git a/scripts/start-in-Xephyr b/scripts/start-in-Xephyr index 0b20b1927..88c79a3b1 100755 --- a/scripts/start-in-Xephyr +++ b/scripts/start-in-Xephyr @@ -29,14 +29,19 @@ try: hexkey = "".join(("%02x" % ord(byte) for byte in key)) # Store that in an xauthority file as the key for connecting to our Xephyr - os.environ['XAUTHORITY'] = xauth_file - retcode = subprocess.call(["xauth", "add", display, "MIT-MAGIC-COOKIE-1", hexkey]) + retcode = subprocess.call(["xauth", + "-f", xauth_file, + "add", display, "MIT-MAGIC-COOKIE-1", hexkey]) if retcode != 0: raise RuntimeError("xauth failed") # Launch Xephyr - xephyr = subprocess.Popen(["Xephyr", display, "-screen", "800x600", "-host-cursor"]) + xephyr = subprocess.Popen(["Xephyr", display, + "-auth", xauth_file, + "-screen", "800x600", + "-host-cursor"]) os.environ['DISPLAY'] = display + os.environ['XAUTHORITY'] = xauth_file # Wait for server to get going: LAME time.sleep(1)